<?php
/**
 * Created by PhpStorm.
 * User: liang
 * Email:1050187159@qq.com
 * Date: 2018/8/20
 * Time: 21:31
 */
namespace Home\Controller;

class CollectsController extends BaseController
{
    public function collectsAdd()
    {
        if (!IS_POST) {
            $this->display('web/Collects/invest');
            exit;
        }

        $Collect = D('Collect');
        if ($Collect->collectsAdd()) {
            $this->ajaxReturn('true');
        } else {
            $this->ajaxReturn($Collect->getError());
        }
    }
}